package com.rampage.multitimers.handler;

import com.rampage.multitimers.bo.TimerConfig;

import android.os.Message;

public class Timer implements Runnable {
	
	private final int INTERVAL = 1000; //in ms
	public static final int WHAT_DEC = 1;
	private TimerHandler handler;

	public Timer(TimerHandler handler) {
		this.handler = handler;
	}

	public void run() {
        handler.postDelayed(this, INTERVAL);
        //Message message = Message.obtain();
        //message.obj = null;
        handler.sendEmptyMessage(Timer.WHAT_DEC);
	}

}
